<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<h1>Javascript的BOM</h1>
<hr>

<a href="history.html">history.html</a>
<script>
    console.log('appName = ' + navigator.appName);
    console.log('appVersion = ' + navigator.appVersion);
    console.log('language = ' + navigator.language);
    //console.log('platform = ' + navigator.platform);  //已经废弃
    console.log('platform = ' + navigator.userAgentData.platform);
    console.log('userAgent = ' + navigator.userAgent);

    console.log("总宽度/高度: ");
    console.log(screen.width + "*" + screen.height);
    console.log("可以宽度/高度: ");
    console.log(screen.availWidth + "*" + screen.availHeight);
    console.log("颜色深度: ");
    console.log(screen.colorDepth);
    console.log("颜色分辨率: ");
    console.log(screen.pixelDepth);

    console.log(location);
    console.log(location.href); //URL
    console.log(location.protocol); // 协议
    console.log(location.host); // 主机域名
    console.log(location.port); // 端口
    console.log(location.pathname); // 路径
    console.log(location.search); // 参数
    console.log(location.hash); // hash


</script>
</body>
</html>